<?xml version="1.0" encoding="ascii"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
          "DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
  <title>pyopenspime.engine.StanzaInterpreter</title>
  <link rel="stylesheet" href="epydoc.css" type="text/css" />
  <script type="text/javascript" src="epydoc.js"></script>
</head>

<body bgcolor="white" text="black" link="blue" vlink="#204080"
      alink="#204080">
<!-- ==================== NAVIGATION BAR ==================== -->
<table class="navbar" border="0" width="100%" cellpadding="0"
       bgcolor="#a0c0ff" cellspacing="0">
  <tr valign="middle">

  <!-- Tree link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="module-tree.html">Trees</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Index link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="identifier-index.html">Indices</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Help link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Project homepage -->
      <th class="navbar" align="right" width="100%">
        <table border="0" cellpadding="0" cellspacing="0">
          <tr><th class="navbar" align="center"
            ><a class="navbar" target="_top" href="http://code.google.com/p/pyopenspime/">PyOpenSpime v0.2</a></th>
          </tr></table></th>
  </tr>
</table>
<table width="100%" cellpadding="0" cellspacing="0">
  <tr valign="top">
    <td width="100%">
      <span class="breadcrumbs">
        Package&nbsp;pyopenspime ::
        <a href="pyopenspime.engine-module.html">Module&nbsp;engine</a> ::
        Class&nbsp;StanzaInterpreter
      </span>
    </td>
    <td>
      <table cellpadding="0" cellspacing="0">
        <!-- hide/show private -->
        <tr><td align="right"><span class="options">[<a href="javascript:void(0);" class="privatelink"
    onclick="toggle_private();">hide&nbsp;private</a>]</span></td></tr>
        <tr><td align="right"><span class="options"
            >[<a href="frames.html" target="_top">frames</a
            >]&nbsp;|&nbsp;<a href="pyopenspime.engine.StanzaInterpreter-class.html"
            target="_top">no&nbsp;frames</a>]</span></td></tr>
      </table>
    </td>
  </tr>
</table>
<!-- ==================== CLASS DESCRIPTION ==================== -->
<h1 class="epydoc">Class StanzaInterpreter</h1><p class="nomargin-top"><span class="codelink"><a href="pyopenspime.engine-pysrc.html#StanzaInterpreter">source&nbsp;code</a></span></p>
<p>Class that handles all outgoing requests and incoming responses. This 
  class also handles key cache management.</p>

<!-- ==================== INSTANCE METHODS ==================== -->
<a name="section-InstanceMethods"></a>
<table class="summary" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr bgcolor="#70b0f0" class="table-header">
  <td colspan="2" class="table-header">
    <table border="0" cellpadding="0" cellspacing="0" width="100%">
      <tr valign="top">
        <td align="left"><span class="table-header">Instance Methods</span></td>
        <td align="right" valign="top"
         ><span class="options">[<a href="#section-InstanceMethods"
         class="privatelink" onclick="toggle_private();"
         >hide private</a>]</span></td>
      </tr>
    </table>
  </td>
</tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pyopenspime.engine.StanzaInterpreter-class.html#__init__" class="summary-sig-name">__init__</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">osid_or_osid_path</span>,
        <span class="summary-sig-arg">rsa_pub_key_path</span>=<span class="summary-sig-default"><code class="variable-quote">'</code><code class="variable-string"></code><code class="variable-quote">'</code></span>,
        <span class="summary-sig-arg">rsa_priv_key_path</span>=<span class="summary-sig-default"><code class="variable-quote">'</code><code class="variable-string"></code><code class="variable-quote">'</code></span>,
        <span class="summary-sig-arg">rsa_priv_key_pass</span>=<span class="summary-sig-default"><code class="variable-quote">'</code><code class="variable-string"></code><code class="variable-quote">'</code></span>,
        <span class="summary-sig-arg">rsa_key_cache_path</span>=<span class="summary-sig-default"><code class="variable-quote">'</code><code class="variable-string">cache</code><code class="variable-quote">'</code></span>,
        <span class="summary-sig-arg">cert_authority</span>=<span class="summary-sig-default"><code class="variable-quote">'</code><code class="variable-string"></code><code class="variable-quote">'</code></span>,
        <span class="summary-sig-arg">accepted_cert_authorities_filepath</span>=<span class="summary-sig-default"><code class="variable-quote">'</code><code class="variable-string">certification-authorities.conf</code><code class="variable-quote">'</code></span>,
        <span class="summary-sig-arg">log_callback_function</span>=<span class="summary-sig-default">None</span>)</span><br />
      Initializes a StanzaInterpreter.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pyopenspime.engine-pysrc.html#StanzaInterpreter.__init__">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">mixed</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pyopenspime.engine.StanzaInterpreter-class.html#validate" class="summary-sig-name">validate</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">stanza</span>,
        <span class="summary-sig-arg">raise_errors</span>=<span class="summary-sig-default">False</span>)</span><br />
      Check if incoming &lt;message/&gt; and &lt;iq/&gt; stanzas are 
      handled by the OpenSpime protocol.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pyopenspime.engine-pysrc.html#StanzaInterpreter.validate">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">pyopenspime.xmpp.simplexml.Node</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pyopenspime.engine.StanzaInterpreter-class.html#encrypt_and_sign" class="summary-sig-name">encrypt_and_sign</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">stanza</span>,
        <span class="summary-sig-arg">encrypt</span>=<span class="summary-sig-default">False</span>,
        <span class="summary-sig-arg">sign</span>=<span class="summary-sig-default">False</span>)</span><br />
      Function that manages encryption and signature of a stanza according 
      to the OpenSpime protocol Core Reference Schema v0.9.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pyopenspime.engine-pysrc.html#StanzaInterpreter.encrypt_and_sign">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">pyopenspime.xmpp.simplexml.Node</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pyopenspime.engine.StanzaInterpreter-class.html#decrypt" class="summary-sig-name">decrypt</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">stanza</span>)</span><br />
      Function that manages decryption of an OpenSpime stanza according to 
      the OpenSpime protocol Core Reference Schema v0.9.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pyopenspime.engine-pysrc.html#StanzaInterpreter.decrypt">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">boolean</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pyopenspime.engine.StanzaInterpreter-class.html#check_signature" class="summary-sig-name">check_signature</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">stanza</span>)</span><br />
      Function that checks signature of an OpenSpime stanza according to 
      the OpenSpime protocol Core Reference Schema v0.9.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pyopenspime.engine-pysrc.html#StanzaInterpreter.check_signature">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">Dictionary</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pyopenspime.engine.StanzaInterpreter-class.html#get_error" class="summary-sig-name">get_error</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">stanza</span>)</span><br />
      Retrieves error condition and description from an error stanza.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pyopenspime.engine-pysrc.html#StanzaInterpreter.get_error">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">pyopenspime.xmpp.protocol.Error</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pyopenspime.engine.StanzaInterpreter-class.html#create_xmpp_error" class="summary-sig-name">create_xmpp_error</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">stanza</span>,
        <span class="summary-sig-arg">error</span>,
        <span class="summary-sig-arg">error_type</span>=<span class="summary-sig-default"><code class="variable-quote">'</code><code class="variable-string">modify</code><code class="variable-quote">'</code></span>)</span><br />
      Retrieves error condition and description from an error stanza.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pyopenspime.engine-pysrc.html#StanzaInterpreter.create_xmpp_error">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
<tr>
    <td width="15%" align="right" valign="top" class="summary">
      <span class="summary-type">&nbsp;</span>
    </td><td class="summary">
      <table width="100%" cellpadding="0" cellspacing="0" border="0">
        <tr>
          <td><span class="summary-sig"><a href="pyopenspime.engine.StanzaInterpreter-class.html#log" class="summary-sig-name">log</a>(<span class="summary-sig-arg">self</span>,
        <span class="summary-sig-arg">level</span>,
        <span class="summary-sig-arg">msg</span>)</span><br />
      Logging function triggered on log messages.</td>
          <td align="right" valign="top">
            <span class="codelink"><a href="pyopenspime.engine-pysrc.html#StanzaInterpreter.log">source&nbsp;code</a></span>
            
          </td>
        </tr>
      </table>
      
    </td>
  </tr>
</table>
<!-- ==================== METHOD DETAILS ==================== -->
<a name="section-MethodDetails"></a>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr bgcolor="#70b0f0" class="table-header">
  <td colspan="2" class="table-header">
    <table border="0" cellpadding="0" cellspacing="0" width="100%">
      <tr valign="top">
        <td align="left"><span class="table-header">Method Details</span></td>
        <td align="right" valign="top"
         ><span class="options">[<a href="#section-MethodDetails"
         class="privatelink" onclick="toggle_private();"
         >hide private</a>]</span></td>
      </tr>
    </table>
  </td>
</tr>
</table>
<a name="__init__"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">__init__</span>(<span class="sig-arg">self</span>,
        <span class="sig-arg">osid_or_osid_path</span>,
        <span class="sig-arg">rsa_pub_key_path</span>=<span class="sig-default"><code class="variable-quote">'</code><code class="variable-string"></code><code class="variable-quote">'</code></span>,
        <span class="sig-arg">rsa_priv_key_path</span>=<span class="sig-default"><code class="variable-quote">'</code><code class="variable-string"></code><code class="variable-quote">'</code></span>,
        <span class="sig-arg">rsa_priv_key_pass</span>=<span class="sig-default"><code class="variable-quote">'</code><code class="variable-string"></code><code class="variable-quote">'</code></span>,
        <span class="sig-arg">rsa_key_cache_path</span>=<span class="sig-default"><code class="variable-quote">'</code><code class="variable-string">cache</code><code class="variable-quote">'</code></span>,
        <span class="sig-arg">cert_authority</span>=<span class="sig-default"><code class="variable-quote">'</code><code class="variable-string"></code><code class="variable-quote">'</code></span>,
        <span class="sig-arg">accepted_cert_authorities_filepath</span>=<span class="sig-default"><code class="variable-quote">'</code><code class="variable-string">certification-authorities.conf</code><code class="variable-quote">'</code></span>,
        <span class="sig-arg">log_callback_function</span>=<span class="sig-default">None</span>)</span>
    <br /><em class="fname">(Constructor)</em>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pyopenspime.engine-pysrc.html#StanzaInterpreter.__init__">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>Initializes a StanzaInterpreter.</p>
  <dl class="fields">
    <dt>Parameters:</dt>
    <dd><ul class="nomargin-top">
        <li><strong class="pname"><code>osid_or_osid_path</code></strong> (str) - The full OSID of the client. If an OpenSpime configuration 
          package is found, this is the only parameter that is needed to 
          initialize the Client.</li>
        <li><strong class="pname"><code>rsa_pub_key_path</code></strong> (unicode) - The path to the RSA public key .pem file. <i>Taken from the 
          OpenSpime configuration package if found</i>.</li>
        <li><strong class="pname"><code>rsa_priv_key_path</code></strong> (unicode) - The path to the RSA private key .pem file. <i>Taken from the 
          OpenSpime configuration package if found</i>.</li>
        <li><strong class="pname"><code>rsa_priv_key_pass</code></strong> (unicode) - The RSA private key .pem file password. <i>Taken from the 
          OpenSpime configuration package if found</i>.</li>
        <li><strong class="pname"><code>rsa_key_cache_path</code></strong> (unicode) - The path to cached public RSA keys of entities. Defaults to 
          <i>/cache</i>.</li>
        <li><strong class="pname"><code>cert_authority</code></strong> (unicode) - The client's certification authority. <i>Taken from the OpenSpime
          configuration package if found</i>.</li>
        <li><strong class="pname"><code>accepted_cert_authorities_filepath</code></strong> (unicode) - The path to the file of accepted certification authorities. 
          Defaults to file <i>certification-authorities.conf</i> in root 
          folder.</li>
        <li><strong class="pname"><code>log_callback_function</code></strong> (function) - Callback function for logger. Function should accept two 
          parameters: unicode (the log description) and integer (the 
          verbosity level - 0 for error, 1 for warning, 2 for info, 3 for 
          debug).</li>
    </ul></dd>
  </dl>
</td></tr></table>
</div>
<a name="validate"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">validate</span>(<span class="sig-arg">self</span>,
        <span class="sig-arg">stanza</span>,
        <span class="sig-arg">raise_errors</span>=<span class="sig-default">False</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pyopenspime.engine-pysrc.html#StanzaInterpreter.validate">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>Check if incoming &lt;message/&gt; and &lt;iq/&gt; stanzas are handled
  by the OpenSpime protocol.</p>
  <dl class="fields">
    <dt>Parameters:</dt>
    <dd><ul class="nomargin-top">
        <li><strong class="pname"><code>stanza</code></strong> (pyopenspime.xmpp.protocol.Stanza) - The incoming stanza.</li>
        <li><strong class="pname"><code>raise_errors</code></strong> (boolean) - If set to True, instead of returning a managed error stanza, 
          function will raise errors.</li>
    </ul></dd>
    <dt>Returns: mixed</dt>
        <dd>if successful:    ReqObj():                              the 
          ReqObj of the extension. if error found:   
          pyopenspime.xmpp.protocol.Protocol:    stanza to be sent out as 
          error.</dd>
  </dl>
</td></tr></table>
</div>
<a name="encrypt_and_sign"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">encrypt_and_sign</span>(<span class="sig-arg">self</span>,
        <span class="sig-arg">stanza</span>,
        <span class="sig-arg">encrypt</span>=<span class="sig-default">False</span>,
        <span class="sig-arg">sign</span>=<span class="sig-default">False</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pyopenspime.engine-pysrc.html#StanzaInterpreter.encrypt_and_sign">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>Function that manages encryption and signature of a stanza according 
  to the OpenSpime protocol Core Reference Schema v0.9.</p>
  <dl class="fields">
    <dt>Parameters:</dt>
    <dd><ul class="nomargin-top">
        <li><strong class="pname"><code>stanza</code></strong> (pyopenspime.xmpp.protocol.Stanza) - The stanza to be encrypted and signed.</li>
        <li><strong class="pname"><code>encrypt</code></strong> (boolean) - If encryption is requested, set to True. Defaults to 
          <i>False</i>.</li>
        <li><strong class="pname"><code>sign</code></strong> (boolean) - If signature is requested, set to True. Defaults to <i>False</i>.</li>
    </ul></dd>
    <dt>Returns: pyopenspime.xmpp.simplexml.Node</dt>
        <dd>The OpenSpime encrypted and signed stanza.</dd>
  </dl>
</td></tr></table>
</div>
<a name="decrypt"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">decrypt</span>(<span class="sig-arg">self</span>,
        <span class="sig-arg">stanza</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pyopenspime.engine-pysrc.html#StanzaInterpreter.decrypt">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>Function that manages decryption of an OpenSpime stanza according to 
  the OpenSpime protocol Core Reference Schema v0.9.</p>
  <dl class="fields">
    <dt>Parameters:</dt>
    <dd><ul class="nomargin-top">
        <li><strong class="pname"><code>stanza</code></strong> (pyopenspime.xmpp.protocol.Stanza) - The stanza to be decrypted.</li>
    </ul></dd>
    <dt>Returns: pyopenspime.xmpp.simplexml.Node</dt>
        <dd>The &lt;openspime/&gt; decrypted stanza node.</dd>
  </dl>
</td></tr></table>
</div>
<a name="check_signature"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">check_signature</span>(<span class="sig-arg">self</span>,
        <span class="sig-arg">stanza</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pyopenspime.engine-pysrc.html#StanzaInterpreter.check_signature">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>Function that checks signature of an OpenSpime stanza according to the
  OpenSpime protocol Core Reference Schema v0.9.</p>
  <dl class="fields">
    <dt>Parameters:</dt>
    <dd><ul class="nomargin-top">
        <li><strong class="pname"><code>stanza</code></strong> (pyopenspime.xmpp.protocol.Stanza) - The stanza to be checked.</li>
    </ul></dd>
    <dt>Returns: boolean</dt>
        <dd>True if signature is valid or stanza not signed, otherwise raises
          errors.</dd>
  </dl>
</td></tr></table>
</div>
<a name="get_error"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">get_error</span>(<span class="sig-arg">self</span>,
        <span class="sig-arg">stanza</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pyopenspime.engine-pysrc.html#StanzaInterpreter.get_error">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>Retrieves error condition and description from an error stanza. 
  Reference is OpenSpime protocol Core Reference Schema v0.9.</p>
  <dl class="fields">
    <dt>Returns: Dictionary</dt>
        <dd>Dictionary containing: error_cond error_description</dd>
  </dl>
</td></tr></table>
</div>
<a name="create_xmpp_error"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">create_xmpp_error</span>(<span class="sig-arg">self</span>,
        <span class="sig-arg">stanza</span>,
        <span class="sig-arg">error</span>,
        <span class="sig-arg">error_type</span>=<span class="sig-default"><code class="variable-quote">'</code><code class="variable-string">modify</code><code class="variable-quote">'</code></span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pyopenspime.engine-pysrc.html#StanzaInterpreter.create_xmpp_error">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>Retrieves error condition and description from an error stanza. 
  Reference is XMPP RFC 3920.</p>
  <dl class="fields">
    <dt>Returns: pyopenspime.xmpp.protocol.Error</dt>
        <dd>Error stanza</dd>
  </dl>
</td></tr></table>
</div>
<a name="log"></a>
<div>
<table class="details" border="1" cellpadding="3"
       cellspacing="0" width="100%" bgcolor="white">
<tr><td>
  <table width="100%" cellpadding="0" cellspacing="0" border="0">
  <tr valign="top"><td>
  <h3 class="epydoc"><span class="sig"><span class="sig-name">log</span>(<span class="sig-arg">self</span>,
        <span class="sig-arg">level</span>,
        <span class="sig-arg">msg</span>)</span>
  </h3>
  </td><td align="right" valign="top"
    ><span class="codelink"><a href="pyopenspime.engine-pysrc.html#StanzaInterpreter.log">source&nbsp;code</a></span>&nbsp;
    </td>
  </tr></table>
  
  <p>Logging function triggered on log messages. Uses the same syntax of 
  logger.Logger.append()</p>
  <dl class="fields">
  </dl>
</td></tr></table>
</div>
<br />
<!-- ==================== NAVIGATION BAR ==================== -->
<table class="navbar" border="0" width="100%" cellpadding="0"
       bgcolor="#a0c0ff" cellspacing="0">
  <tr valign="middle">

  <!-- Tree link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="module-tree.html">Trees</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Index link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="identifier-index.html">Indices</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Help link -->
      <th>&nbsp;&nbsp;&nbsp;<a
        href="help.html">Help</a>&nbsp;&nbsp;&nbsp;</th>

  <!-- Project homepage -->
      <th class="navbar" align="right" width="100%">
        <table border="0" cellpadding="0" cellspacing="0">
          <tr><th class="navbar" align="center"
            ><a class="navbar" target="_top" href="http://code.google.com/p/pyopenspime/">PyOpenSpime v0.2</a></th>
          </tr></table></th>
  </tr>
</table>
<table border="0" cellpadding="0" cellspacing="0" width="100%%">
  <tr>
    <td align="left" class="footer">
    Generated by Epydoc 3.0.1 on Thu Dec 18 12:31:01 2008
    </td>
    <td align="right" class="footer">
      <a target="mainFrame" href="http://epydoc.sourceforge.net"
        >http://epydoc.sourceforge.net</a>
    </td>
  </tr>
</table>

<script type="text/javascript">
  <!--
  // Private objects are initially displayed (because if
  // javascript is turned off then we want them to be
  // visible); but by default, we want to hide them.  So hide
  // them unless we have a cookie that says to show them.
  checkCookie();
  // -->
</script>
</body>
</html>
